<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8" %>
<%@include file="/context/mytags.jsp" %>
<div class="table-scrollable">
    <table class="table table-striped table-hover table-success">
        <thead>
        <tr>
            <th class="text-center">序号</th>
            <th class="text-center">订单编号</th>
            <th class="text-center">预约时间</th>
            <th class="text-center">真实姓名</th>
            <th class="text-center">性别</th>
            <th class="text-center">年龄</th>
            <th class="text-center">手机号</th>
            <th class="text-center">确认订单</th>
            <th class="text-center">科室</th>
        </tr>
        </thead>
        <tbody>
        <c:forEach items="${page.result}" var="orders" varStatus="vs">
            <tr class="text-center">
                <td>${vs.count + page.offset}</td>
                <%--订单编号--%>
                <td>${orders.orderCode}</td>
                <%--预约时间--%>
                <td>
                    <fmt:formatDate value="${orders.appointmentTime}" pattern="yyyy-MM-dd" />
                </td>
                <%--真实姓名--%>
                <td>${orders.patientName}</td>
                <%--性别:1、男，0、女，2、保密--%>
                <td>
                    <c:if test="${orders.patientSex == 0}">女</c:if>
                    <c:if test="${orders.patientSex == 1}">男</c:if>
                    <c:if test="${orders.patientSex == 2}">保密</c:if>
                </td>
                <%--年龄--%>
                <td>${orders.patientAge}</td>
                <%--手机号--%>
                <td>${orders.patientPhone}</td>
                <%--确认订单--%>
                <td>
                    <a href="javascript:;"
                       onclick="comfirmOrder('${orders.orderId}')">
                            立即确认
                    </a>
                </td>
                <%--科室--%>
                <td>${orders.departmentName}</td>
            </tr>
        </c:forEach>
        </tbody>
    </table>
</div>
<div class="pageination-panel">${page}</div>